<template>
  <div>
    <div v-if="isJumped">
      <h5>
        <el-link @click="handleJump">已跳转，点击 <el-link type="primary">重新跳转</el-link></el-link>
      </h5>
    </div>
    <div v-else>跳转中...</div>
  </div>
</template>

<script setup lang="ts">
import { onMounted, ref } from 'vue';
import { getToken } from '@/modules/app-gateway';
defineOptions({ name: 'DyjPut' });
const isJumped = ref(false);
const handleJump = () => {
  const url = `http://admin-dyj.kaogujia.com/storePopularize/launchOrderStore?crmToken=${getToken()}`;
  console.log(url);
  window.open(url, '_blank');
  isJumped.value = true;
};
onMounted(handleJump);
</script>
